import Vue from 'vue'
import Vuex from 'vuex'

Vue.use(Vuex)

export default new Vuex.Store({
  state: {
    routes:[],
    roleId:0,
  },
  mutations: {
    initRoutes(state,data){
      state.routes=data
    },
    initroleId(state,data){
      state.roleId=data
    }
  },
  actions: {
    updateInfoByAction({commit},roleId){
      commit("initroleId",roleId);
    }
  },
  modules: {
  }
})
